package com.example.gateway;

import com.netflix.hystrix.contrib.javanica.annotation.HystrixCommand;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;

@FeignClient(name = "SERVICE-NAME")
public interface MyFeignClient {
    @HystrixCommand(fallbackMethod = "fallbackMethod")
    @GetMapping("/endpoint")
    String callService();

    String fallbackMethod();
}
